<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>六西格玛知识管理</title>
<link href="<?php echo $this->baseUrl ?>/public/style/style.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $this->baseUrl ?>/public/style/form-check.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $this->baseUrl ?>/public/style/daterangepicker.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $this->baseUrl ?>/public/style/jquery-ui.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $this->baseUrl ?>/public/style/thickbox.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/scripts/jquery.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/scripts/daterangepicker.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/scripts/jquery-ui.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/scripts/thickbox-compressed.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/scripts/jQuery.FormValidator.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/fckeditor/fckeditor.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl ?>/public/scripts/jQuery.FormValidator.js"></script>

<script type="text/javascript">
	function CheckForm() {
		return $("#form1").FormValidate();
	}
	$(document).ready(function() {
		$("#form1").SetValidateSettings({});
		$("#name").SetValidateSettings({
			FormValidate: {
				Empty: {
					Value: true,
					Message: "学生姓名不能为空"
				}
			},
			Message: {
				Text: {
					Success: "",
					Error: "必须输入学生姓名！"
				},
				MessageSpaceHolderID: "TipTitle"
			}
		});
		
		$("#delete_photo").click(function(){
			$("#photo_del").val("1");
			$("#cr_pic").hide();
		})
	});
</script>

</head>

<body>
<!--头部-->
<?php echo $this->partial('common/header.html', array('template'=>$this->template, 'baseUrl'=>$this->baseUrl)) ?>

<!--主体-->
<div class="main-box" id="mainBox">
    <div class="third-menu">
        <?php echo $this->partial('common/operation.html', array('template'=>$this->template, 'baseUrl'=>$this->baseUrl)) ?>
        <div class="menu-title"><span class="icon"></span>学生修改</div>
    </div>
  
	<div class="separate-line"></div>
    <div class="main-form">
        <form name="form1" id="form1" method="post" action="<?php echo $this->baseUrl ?>/student/edit?student_id=<?php echo $_GET['student_id'] ?>" enctype="multipart/form-data">
                <input type="hidden" name="photo_del" id="photo_del" value="0" />
            <p>
                <label for="name">学生姓名：</label>
                <input name="name" type="text" class="input-text" value="<?php echo $this->student[0]['name'] ?>" id="name" />
                <span id="TipTitle" class="Show"></span>
            </p>
            <p><label for="pinyin">姓名拼音：</label><input name="pinyin" type="text" class="input-text" value="<?php echo $this->student[0]['pinyin'] ?>" /></p>
            <p>
                <label for="sex">学生性别：</label>
                <select name="sex" type="text" class="input-text">
                    <option value="1" <?php if ($this->student[0]['sex']==1):?>selected='selected'<?php endif; ?>>男</option>
                    <option value="0" <?php if ($this->student[0]['sex']==0):?>selected='selected'<?php endif; ?>>女</option>
            </select>
            </p>
            <p>
                <label for="company">所属客户：</label>
                <input name="company_name" type="text" class="input-text" id="company_name_hover" disabled="disabled" value="<?php echo !empty($this->company_name)?$this->company_name:''; ?>" />
                <input name="company_id" type="hidden" id="company_id_hover" value="<?php echo $this->student[0]['company_id'] ?>" />
                <a href="<?php echo $this->baseUrl ?>/company/add" class="color-button button">添加客户</a>
                <a href="<?php echo $this->baseUrl ?>/company/hover?keepThis=true&TB_iframe=true&height=360&width=330" class="button thickbox">选择客户</a></p>
            <p><label for="email">邮件地址：</label><input name="email" type="text" class="input-text" value="<?php echo $this->student[0]['email'] ?>" /></p>
            <p><label for="telephone">固定电话：</label><input name="telephone" type="text" class="input-text" value="<?php echo $this->student[0]['telephone'] ?>" /></p>
            <p><label for="mobile">移动电话：</label><input name="mobile" type="text" class="input-text" value="<?php echo $this->student[0]['mobile'] ?>" /></p>
            <p><label for="duties">学习时职务：</label><input name="duties" type="text" class="input-text" value="<?php echo $this->student[0]['duties'] ?>" /></p>
            <p><label for="post">现任职务：</label><input name="duties_now" type="text" class="input-text" value="<?php echo $this->student[0]['duties_now'] ?>" /></p>
            <?php if($this->student[0]['photo']!=""){?><p><label for="photo">学生照片：</label><img src="<?php echo $this->baseUrl ?>/<?php echo $this->student[0]['photo'];?>" width="160" height="200" id="cr_pic"/><span id="delete_photo">删除照片</span></p><?php }?>
            <p><label for="photo">更新照片：</label><input name="photo" type="file" class="input-file" /><input type="hidden" name="current_photo" value="<?php echo $this->student[0]['photo'];?>" /></p>
            <p><label for="summary">学生简介：</label><textarea name="summary" class="input-textarea" ><?php echo $this->student[0]['summary'] ?></textarea></p>
            <p><label>&nbsp;</label><input type="submit" class="button" style="margin-left:0" value="提 交" /></p>
        </form>
    </div>
</div>










<!--底部-->
<?php echo $this->partial('common/footer.html') ?>
</body>
</html>
